<!-- $Id: flashsale_list.htm 14216 2008-03-10 02:27:21Z testyang $ -->



{if $full_page}

{include file="pageheader.htm"}

{insert_scripts files="../js/utils.js,listtable.js"}



<div class="form-div">

  <form action="javascript:searchActivity()" name="searchForm">

    <img src="images/icon_search.gif" width="26" height="22" border="0" alt="SEARCH" />

    {$lang.goods_name} <input type="text" name="keyword" size="30" />

    <input name="is_going" type="checkbox" id="is_going" value="1" />

    {$lang.act_is_going}

    <input type="submit" value="{$lang.button_search}" class="button" />

  </form>

</div>



<form method="post" action="flashsale.php" name="listForm" onsubmit="return confirm(batch_drop_confirm);">

<!-- start flashsale list -->

<div class="list-div" id="listDiv">

{/if}



  <table cellpadding="3" cellspacing="1">

    <tr>

      <th>

        <input onclick='listTable.selectAll(this, "checkboxes")' type="checkbox" />

        <a href="javascript:listTable.sort('act_id'); ">{$lang.record_id}</a>{$sort_act_id}</th>

      <th><a href="javascript:listTable.sort('act_name'); ">{$lang.act_name}</a>{$sort_act_name}</th>

      <th><a href="javascript:listTable.sort('start_date'); ">{$lang.start_date}</a>{$sort_start_date}</th>

      <th><a href="javascript:listTable.sort('end_date'); ">{$lang.end_date}</a>{$sort_end_date}</th>

      <th><a href="javascript:listTable.sort('start_time'); ">{$lang.start_time}</a>{$sort_start_time}</th>

      <th><a href="javascript:listTable.sort('end_time'); ">{$lang.end_time}</a>{$sort_end_time}</th>

      <th>{$lang.min_amount}</th>

      <th>{$lang.max_amount}</th>

      <th><a href="javascript:listTable.sort('sort_order'); ">{$lang.sort_order}</a>{$sort_sort_order}</th>

      <th>{$lang.handler}</th>

    </tr>



    {foreach from=$flashsale_list item=flashsale}

    <tr>

      <td><input value="{$flashsale.act_id}" name="checkboxes[]" type="checkbox">{$flashsale.act_id}</td>

      <td>{$flashsale.act_name|escape:html}</td>

      <td align="right">{$flashsale.start_date}</td>

      <td align="right">{$flashsale.end_date}</td>

      <td align="right">{$flashsale.start_time}</td>

      <td align="right">{$flashsale.end_time}</td>

      <td align="right">{$flashsale.min_amount}</td>

      <td align="right">{$flashsale.max_amount}</td>

      <td align="center"><span onclick="listTable.edit(this, 'edit_sort_order', {$flashsale.act_id})">{$flashsale.sort_order}</span></td>

      <td align="center">

        <a href="flashsale.php?act=edit&amp;id={$flashsale.act_id}" title="{$lang.edit}"><img src="images/icon_edit.gif" border="0" height="16" width="16" /></a>

        <a href="javascript:;" onclick="listTable.remove({$flashsale.act_id},'{$lang.drop_confirm}')" title="{$lang.remove}"><img src="images/icon_drop.gif" border="0" height="16" width="16" /></a>      </td>

    </tr>

    {foreachelse}

    <tr><td class="no-records" colspan="13">{$lang.no_records}</td></tr>

    {/foreach}

  </table>



  <table cellpadding="4" cellspacing="0">

    <tr>

      <td><input type="submit" name="drop" id="btnSubmit" value="{$lang.drop}" class="button" disabled="true" />

      <input type="hidden" name="act" value="batch" /></td>

      <td align="right">{include file="page.htm"}</td>

    </tr>

  </table>



{if $full_page}

</div>

<!-- end flashsale list -->

</form>



<script type="text/javascript" language="JavaScript">

<!--

  listTable.recordCount = {$record_count};

  listTable.pageCount = {$page_count};



  {foreach from=$filter item=item key=key}

  listTable.filter.{$key} = '{$item}';

  {/foreach}



  {literal}

  onload = function()

  {

    document.forms['searchForm'].elements['keyword'].focus();



    startCheckOrder();

  }



  /**

   * 搜索团购活动

   */

  function searchActivity()

  {



    var keyword = Utils.trim(document.forms['searchForm'].elements['keyword'].value);

    listTable.filter['keyword'] = keyword;

    if (document.forms['searchForm'].elements['is_going'].checked)

    {

      listTable.filter['is_going'] = 1;

    }

    else

    {

      listTable.filter['is_going'] = 0;

    }

    listTable.filter['page'] = 1;

    listTable.loadList("flashsale_list");

  }

  {/literal}

//-->

</script>



{include file="pagefooter.htm"}

{/if}